package com.ama.controller;

import com.ama.model.User;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class MvcController {
    @RequestMapping(value = "/boot/getUser" , method = RequestMethod.GET)
    public String getUser(){
        User user = new User();
        user.setName("aaa");
        user.setPassword("123");
        return user.getName();
    }

    @GetMapping("/boot/getPassword")
    public String getPassword(){
        User user = new User();
        user.setName("aaa");
        user.setPassword("123");
        return user.getPassword();
    }
}
